<template>
  <div>
    <div id="banner">

      <div class="lbta">
              <el-carousel indicator-position="outside">
          <el-carousel-item v-for="item in img_list" :key="item">
            <img :src="item" />
          </el-carousel-item>
        </el-carousel>
      </div>

      <div id="ck">
        <div id="select">
          <ul id="list">
            <li v-for="zu in zu_list" :key="zu.id"><a href="">{{zu.txt}}</a></li>
          </ul>
          <div id="inptext">
            <el-input type="text" placeholder="请输入内容"></el-input>
          </div>
          <el-button type="primary" icon="el-icon-search">搜索</el-button>
          <el-button type="primary">地图找房</el-button>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
  export default {
    name: "Banner",
    data() {
      return {
        // 图片地址数组
        img_list: ["../../../images/tp1.jpg",
          "../../../images/tp2.jpg",
          "../../../images/tp3.jpg"
        ],
        zu_list: [{
            txt: '查房价',
          },
          {
            txt: '买新房',
          },
          {
            txt: '买二手房',
          },
          {
            txt: '找租房',
          },
          {
            txt: '找商铺',
          },
          {
            txt: '装修家居',
          },
          {
            txt: '房产快讯',
          },
          {
            txt: '海外房产',
          }
        ],
      };
    },
    methods: {},
    mounted() {}
  };
</script>

<style scoped="scoped">
  /* 轮播图*/
  .lbta {
    width: 100%;
  }

  .el-carousel__item h3 {
    color: #475669;
    font-size: 18px;
    opacity: 0.75;
    line-height: 300px;
    margin: 0;
  }

  .el-carousel__item:nth-child(2n) {
    background-color: #99a9bf;
  }

  .el-carousel__item:nth-child(2n+1) {
    background-color: #d3dce6;
  }

  /* 搜索*/
  #ck {
    width: 600px;
    height: 200px;
    background: #222132;
    background-color: rgba(0, 0, 0, 0.4);
    border-radius: 6px;
    margin-left: 500px;
    margin-top: -270px;
    position: absolute;
    z-index: 5;
  }

  #select {
    padding-left: 30px;
    padding-top: 60px;
    margin: 0;
  }

  #inptext {
    width: 60%;
    height: 40px;
    display: inline-block;
    border-radius: 6px;
  }

  #list {
    margin-top: 30px;
  }

  #list li a {
    color: white;
    text-decoration: none;
    margin: 0;
    line-height: 3;
  }

  #list li:hover {
    background-color: red;
  }

  #list li {
    width: 50px;
    height: 30px;
    list-style: none;
    display: inline-block;
    font-size: 10px;
    vertical-align: middle;
    text-align: center;

  }
</style>
